﻿namespace NetTask5
{
    class Program
    {
        private static readonly DeviceHeader[] Devices =
            new[]
                {
                    new DeviceHeader
                        {Name = "SystemName", Query = "Win32_DesktopMonitor", Bloks = new[] {"SystemName"}}
                    , new DeviceHeader
                          {
                              Name = "Motherboard",
                              Query = "Win32_ComputerSystem",
                              Bloks = new[] {"Manufacturer", "Model"}
                          }
                    , new DeviceHeader
                          {Name = "VideoController", Query = "Win32_VideoController", Bloks = new[] {"Name"}}
                    , new DeviceHeader
                          {Name = "Drive", Query = "Win32_DiskDrive", Bloks = new[] {"Model", "Size"}}
                    , new DeviceHeader
                          {
                              Name = "Monitor",
                              Query = "Win32_DesktopMonitor",
                              Bloks = new[] {"Caption", "MonitorManufacturer"}
                          }
                    , new DeviceHeader
                          {
                              Name = "Processor",
                              Query = "Win32_Processor",
                              Bloks = new[] {"Manufacturer", "Name", "NumberOfCores"}
                          }
                    , new DeviceHeader
                          {
                              Name = "NetworkAdapter",
                              Query = "Win32_NetworkAdapter",
                              Bloks = new[] {"Manufacturer", "Name", "AdapterType"}
                          }
                    , new DeviceHeader
                          {
                              Name = "RAM",
                              Query = "Win32_PhysicalMemory",
                              Bloks = new[] {"Manufacturer", "Name", "Capacity"}
                          }
                    , new DeviceHeader
                          {Name = "CD-ROM", Query = "Win32_CDROMDrive", Bloks = new[] {"Name"}}
                    , new DeviceHeader
                          {Name = "FloppyDrive", Query = "Win32_FloppyDrive", Bloks = new[] {"Name"}}
                    , new DeviceHeader
                          {Name = "SoundDevise", Query = "Win32_SoundDevice", Bloks = new[] {"Name"}}
                    , new DeviceHeader
                          {Name = "Mouse", Query = "Win32_PointingDevice", Bloks = new[] {"Name"}}
                    , new DeviceHeader
                          {Name = "Keyboard", Query = "Win32_Keyboard", Bloks = new[] {"Name"}}
                };

        static void Main()
        {
            var hi = new Hardware();
            hi.GetHardWareInfo(Devices, "out.xml", "out.xsl" );
        }
    }
}
